package com.dragon.modules.yuegou.query.member;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.dragon.modules.yuegou.entity.member.LevelEntity;
import com.dragon.modules.yuegou.enums.member.LevelCycle;
import com.dragon.modules.yuegou.mybatis.Condition;
import com.dragon.modules.yuegou.mybatis.Query;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
import com.fasterxml.jackson.annotation.JsonUnwrapped;

import java.time.LocalDateTime;

/**
 * 会员等级表 动态查询条件
 *
 * @author pbuilder generated
 * @date 2021-06-30 15:45:58
 * @version 2.0
 */
@JsonInclude(Include.NON_NULL)
public class LevelQuery extends LevelEntity implements Query<LevelEntity> {

	private static final long serialVersionUID = 1L;


	/** 查询条件 */
	@JsonUnwrapped(prefix = "id")
	private Condition<String> idCondition;

	/** 查询条件 */
	@JsonUnwrapped(prefix = "busdId")
	private Condition<String> busdIdCondition;

	/** 会员名称查询条件 */
	@JsonUnwrapped(prefix = "name")
	private Condition<String> nameCondition;

	/** [枚举]重置周期：0-当年-THATYEAR、1-当月-THATMONTH、2-滚动年-ROLLINGYEAR、3-滚动月-ROLLINGMONTH查询条件 */
	@JsonUnwrapped(prefix = "cycle")
	private Condition<LevelCycle> cycleCondition;

	/** 查询条件 */
	@JsonUnwrapped(prefix = "img")
	private Condition<String> imgCondition;

	/** 等级需要累计积分查询条件 */
	@JsonUnwrapped(prefix = "points")
	private Condition<Integer> pointsCondition;

	/** 原始积分查询条件 */
	@JsonUnwrapped(prefix = "originalPoints")
	private Condition<Integer> originalPointsCondition;

	/** 获得积分查询条件 */
	@JsonUnwrapped(prefix = "obtainPoints")
	private Condition<Integer> obtainPointsCondition;

	/** 会员权益查询条件 */
	@JsonUnwrapped(prefix = "rights")
	private Condition<String> rightsCondition;

	/** 会员权益图片查询条件 */
	@JsonUnwrapped(prefix = "rightsImg")
	private Condition<String> rightsImgCondition;

	/** 等级编号查询条件 */
	@JsonUnwrapped(prefix = "serialNumber")
	private Condition<Integer> serialNumberCondition;

	/** 查询条件 */
	@JsonUnwrapped(prefix = "createdTime")
	private Condition<LocalDateTime> createdTimeCondition;

	/** 查询条件 */
	@JsonUnwrapped(prefix = "createdBy")
	private Condition<String> createdByCondition;

	/** 查询条件 */
	@JsonUnwrapped(prefix = "modifiedTime")
	private Condition<LocalDateTime> modifiedTimeCondition;

	/** 查询条件 */
	@JsonUnwrapped(prefix = "modifiedBy")
	private Condition<String> modifiedByCondition;

	/** 逻辑删除，1表示已删除,0表示未删除查询条件 */
	@JsonUnwrapped(prefix = "del")
	private Condition<Boolean> delCondition;

	/** 查询条件 */
	@JsonUnwrapped(prefix = "delBy")
	private Condition<String> delByCondition;

	/** 查询条件 */
	@JsonUnwrapped(prefix = "delTime")
	private Condition<LocalDateTime> delTimeCondition;

	/**
	 * 构造一个查询条件对象
	 */
	public LevelQuery() {
		super();
	}

	/**
	 * 依据实体对象构造一个查询条件对象
	 *
	 * @param entity 实体对象
	 */
	public LevelQuery(LevelEntity entity) {
		super(entity);
	}

	/**
	 * 依据其它查询条件对象的信息构造一个查询条件对象
	 *
	 * @param other 查询条件对象
	 */
	public LevelQuery(LevelQuery other) {
		super(other);
		if(other.idCondition != null) {
			this.idCondition = other.idCondition.copy();
		}
		if(other.busdIdCondition != null) {
			this.busdIdCondition = other.busdIdCondition.copy();
		}
		if(other.nameCondition != null) {
			this.nameCondition = other.nameCondition.copy();
		}
		if(other.cycleCondition != null) {
			this.cycleCondition = other.cycleCondition.copy();
		}
		if(other.imgCondition != null) {
			this.imgCondition = other.imgCondition.copy();
		}
		if(other.pointsCondition != null) {
			this.pointsCondition = other.pointsCondition.copy();
		}
		if(other.originalPointsCondition != null) {
			this.originalPointsCondition = other.originalPointsCondition.copy();
		}
		if(other.obtainPointsCondition != null) {
			this.obtainPointsCondition = other.obtainPointsCondition.copy();
		}
		if(other.rightsCondition != null) {
			this.rightsCondition = other.rightsCondition.copy();
		}
		if(other.rightsImgCondition != null) {
			this.rightsImgCondition = other.rightsImgCondition.copy();
		}
		if(other.serialNumberCondition != null) {
			this.serialNumberCondition = other.serialNumberCondition.copy();
		}
		if(other.createdTimeCondition != null) {
			this.createdTimeCondition = other.createdTimeCondition.copy();
		}
		if(other.createdByCondition != null) {
			this.createdByCondition = other.createdByCondition.copy();
		}
		if(other.modifiedTimeCondition != null) {
			this.modifiedTimeCondition = other.modifiedTimeCondition.copy();
		}
		if(other.modifiedByCondition != null) {
			this.modifiedByCondition = other.modifiedByCondition.copy();
		}
		if(other.delCondition != null) {
			this.delCondition = other.delCondition.copy();
		}
		if(other.delByCondition != null) {
			this.delByCondition = other.delByCondition.copy();
		}
		if(other.delTimeCondition != null) {
			this.delTimeCondition = other.delTimeCondition.copy();
		}
	}

	@Override
	public QueryWrapper<LevelEntity> toQueryWrapper() {
		QueryWrapper<LevelEntity> wrapper = new QueryWrapper<>(this);
		if (idCondition != null) {
			idCondition.toWrapper(wrapper, COL_ID);
		}
		if (busdIdCondition != null) {
			busdIdCondition.toWrapper(wrapper, COL_BUSD_ID);
		}
		if (nameCondition != null) {
			nameCondition.toWrapper(wrapper, COL_NAME);
		}
		if (cycleCondition != null) {
			cycleCondition.toWrapper(wrapper, COL_CYCLE);
		}
		if (imgCondition != null) {
			imgCondition.toWrapper(wrapper, COL_IMG);
		}
		if (pointsCondition != null) {
			pointsCondition.toWrapper(wrapper, COL_POINTS);
		}
		if (originalPointsCondition != null) {
			originalPointsCondition.toWrapper(wrapper, COL_ORIGINAL_POINTS);
		}
		if (obtainPointsCondition != null) {
			obtainPointsCondition.toWrapper(wrapper, COL_OBTAIN_POINTS);
		}
		if (rightsCondition != null) {
			rightsCondition.toWrapper(wrapper, COL_RIGHTS);
		}
		if (rightsImgCondition != null) {
			rightsImgCondition.toWrapper(wrapper, COL_RIGHTS_IMG);
		}
		if (serialNumberCondition != null) {
			serialNumberCondition.toWrapper(wrapper, COL_SERIAL_NUMBER);
		}
		if (createdTimeCondition != null) {
			createdTimeCondition.toWrapper(wrapper, COL_CREATED_TIME);
		}
		if (createdByCondition != null) {
			createdByCondition.toWrapper(wrapper, COL_CREATED_BY);
		}
		if (modifiedTimeCondition != null) {
			modifiedTimeCondition.toWrapper(wrapper, COL_MODIFIED_TIME);
		}
		if (modifiedByCondition != null) {
			modifiedByCondition.toWrapper(wrapper, COL_MODIFIED_BY);
		}
		if (delCondition != null) {
			delCondition.toWrapper(wrapper, COL_DEL);
		}
		if (delByCondition != null) {
			delByCondition.toWrapper(wrapper, COL_DEL_BY);
		}
		if (delTimeCondition != null) {
			delTimeCondition.toWrapper(wrapper, COL_DEL_TIME);
		}
		return wrapper;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return idCondition 查询条件
	 */
	public Condition<String> id() {
		this.idCondition = new Condition<>();
		return this.idCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return idCondition 查询条件
	 */
	public Condition<String> getIdCondition() {
		return idCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param idCondition 查询条件
	 */
	public void setIdCondition(Condition<String> idCondition) {
		this.idCondition = idCondition;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return busdIdCondition 查询条件
	 */
	public Condition<String> busdId() {
		this.busdIdCondition = new Condition<>();
		return this.busdIdCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return busdIdCondition 查询条件
	 */
	public Condition<String> getBusdIdCondition() {
		return busdIdCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param busdIdCondition 查询条件
	 */
	public void setBusdIdCondition(Condition<String> busdIdCondition) {
		this.busdIdCondition = busdIdCondition;
	}

	/**
	 * 构造并返回会员名称查询条件
	 *
	 * @return nameCondition 会员名称查询条件
	 */
	public Condition<String> name() {
		this.nameCondition = new Condition<>();
		return this.nameCondition;
	}

	/**
	 * 获取会员名称查询条件
	 *
	 * @return nameCondition 会员名称查询条件
	 */
	public Condition<String> getNameCondition() {
		return nameCondition;
	}

	/**
	 * 设置会员名称查询条件
	 *
	 * @param nameCondition 会员名称查询条件
	 */
	public void setNameCondition(Condition<String> nameCondition) {
		this.nameCondition = nameCondition;
	}

	/**
	 * 构造并返回[枚举]重置周期：0-当年-THATYEAR、1-当月-THATMONTH、2-滚动年-ROLLINGYEAR、3-滚动月-ROLLINGMONTH查询条件
	 *
	 * @return cycleCondition [枚举]重置周期：0-当年-THATYEAR、1-当月-THATMONTH、2-滚动年-ROLLINGYEAR、3-滚动月-ROLLINGMONTH查询条件
	 */
	public Condition<LevelCycle> cycle() {
		this.cycleCondition = new Condition<>();
		return this.cycleCondition;
	}

	/**
	 * 获取[枚举]重置周期：0-当年-THATYEAR、1-当月-THATMONTH、2-滚动年-ROLLINGYEAR、3-滚动月-ROLLINGMONTH查询条件
	 *
	 * @return cycleCondition [枚举]重置周期：0-当年-THATYEAR、1-当月-THATMONTH、2-滚动年-ROLLINGYEAR、3-滚动月-ROLLINGMONTH查询条件
	 */
	public Condition<LevelCycle> getCycleCondition() {
		return cycleCondition;
	}

	/**
	 * 设置[枚举]重置周期：0-当年-THATYEAR、1-当月-THATMONTH、2-滚动年-ROLLINGYEAR、3-滚动月-ROLLINGMONTH查询条件
	 *
	 * @param cycleCondition [枚举]重置周期：0-当年-THATYEAR、1-当月-THATMONTH、2-滚动年-ROLLINGYEAR、3-滚动月-ROLLINGMONTH查询条件
	 */
	public void setCycleCondition(Condition<LevelCycle> cycleCondition) {
		this.cycleCondition = cycleCondition;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return imgCondition 查询条件
	 */
	public Condition<String> img() {
		this.imgCondition = new Condition<>();
		return this.imgCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return imgCondition 查询条件
	 */
	public Condition<String> getImgCondition() {
		return imgCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param imgCondition 查询条件
	 */
	public void setImgCondition(Condition<String> imgCondition) {
		this.imgCondition = imgCondition;
	}

	/**
	 * 构造并返回等级需要累计积分查询条件
	 *
	 * @return pointsCondition 等级需要累计积分查询条件
	 */
	public Condition<Integer> points() {
		this.pointsCondition = new Condition<>();
		return this.pointsCondition;
	}

	/**
	 * 获取等级需要累计积分查询条件
	 *
	 * @return pointsCondition 等级需要累计积分查询条件
	 */
	public Condition<Integer> getPointsCondition() {
		return pointsCondition;
	}

	/**
	 * 设置等级需要累计积分查询条件
	 *
	 * @param pointsCondition 等级需要累计积分查询条件
	 */
	public void setPointsCondition(Condition<Integer> pointsCondition) {
		this.pointsCondition = pointsCondition;
	}

	/**
	 * 构造并返回原始积分查询条件
	 *
	 * @return originalPointsCondition 原始积分查询条件
	 */
	public Condition<Integer> originalPoints() {
		this.originalPointsCondition = new Condition<>();
		return this.originalPointsCondition;
	}

	/**
	 * 获取原始积分查询条件
	 *
	 * @return originalPointsCondition 原始积分查询条件
	 */
	public Condition<Integer> getOriginalPointsCondition() {
		return originalPointsCondition;
	}

	/**
	 * 设置原始积分查询条件
	 *
	 * @param originalPointsCondition 原始积分查询条件
	 */
	public void setOriginalPointsCondition(Condition<Integer> originalPointsCondition) {
		this.originalPointsCondition = originalPointsCondition;
	}

	/**
	 * 构造并返回获得积分查询条件
	 *
	 * @return obtainPointsCondition 获得积分查询条件
	 */
	public Condition<Integer> obtainPoints() {
		this.obtainPointsCondition = new Condition<>();
		return this.obtainPointsCondition;
	}

	/**
	 * 获取获得积分查询条件
	 *
	 * @return obtainPointsCondition 获得积分查询条件
	 */
	public Condition<Integer> getObtainPointsCondition() {
		return obtainPointsCondition;
	}

	/**
	 * 设置获得积分查询条件
	 *
	 * @param obtainPointsCondition 获得积分查询条件
	 */
	public void setObtainPointsCondition(Condition<Integer> obtainPointsCondition) {
		this.obtainPointsCondition = obtainPointsCondition;
	}

	/**
	 * 构造并返回会员权益查询条件
	 *
	 * @return rightsCondition 会员权益查询条件
	 */
	public Condition<String> rights() {
		this.rightsCondition = new Condition<>();
		return this.rightsCondition;
	}

	/**
	 * 获取会员权益查询条件
	 *
	 * @return rightsCondition 会员权益查询条件
	 */
	public Condition<String> getRightsCondition() {
		return rightsCondition;
	}

	/**
	 * 设置会员权益查询条件
	 *
	 * @param rightsCondition 会员权益查询条件
	 */
	public void setRightsCondition(Condition<String> rightsCondition) {
		this.rightsCondition = rightsCondition;
	}

	/**
	 * 构造并返回会员权益图片查询条件
	 *
	 * @return rightsImgCondition 会员权益图片查询条件
	 */
	public Condition<String> rightsImg() {
		this.rightsImgCondition = new Condition<>();
		return this.rightsImgCondition;
	}

	/**
	 * 获取会员权益图片查询条件
	 *
	 * @return rightsImgCondition 会员权益图片查询条件
	 */
	public Condition<String> getRightsImgCondition() {
		return rightsImgCondition;
	}

	/**
	 * 设置会员权益图片查询条件
	 *
	 * @param rightsImgCondition 会员权益图片查询条件
	 */
	public void setRightsImgCondition(Condition<String> rightsImgCondition) {
		this.rightsImgCondition = rightsImgCondition;
	}

	/**
	 * 构造并返回等级编号查询条件
	 *
	 * @return serialNumberCondition 等级编号查询条件
	 */
	public Condition<Integer> serialNumber() {
		this.serialNumberCondition = new Condition<>();
		return this.serialNumberCondition;
	}

	/**
	 * 获取等级编号查询条件
	 *
	 * @return serialNumberCondition 等级编号查询条件
	 */
	public Condition<Integer> getSerialNumberCondition() {
		return serialNumberCondition;
	}

	/**
	 * 设置等级编号查询条件
	 *
	 * @param serialNumberCondition 等级编号查询条件
	 */
	public void setSerialNumberCondition(Condition<Integer> serialNumberCondition) {
		this.serialNumberCondition = serialNumberCondition;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return createdTimeCondition 查询条件
	 */
	public Condition<LocalDateTime> createdTime() {
		this.createdTimeCondition = new Condition<>();
		return this.createdTimeCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return createdTimeCondition 查询条件
	 */
	public Condition<LocalDateTime> getCreatedTimeCondition() {
		return createdTimeCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param createdTimeCondition 查询条件
	 */
	public void setCreatedTimeCondition(Condition<LocalDateTime> createdTimeCondition) {
		this.createdTimeCondition = createdTimeCondition;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return createdByCondition 查询条件
	 */
	public Condition<String> createdBy() {
		this.createdByCondition = new Condition<>();
		return this.createdByCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return createdByCondition 查询条件
	 */
	public Condition<String> getCreatedByCondition() {
		return createdByCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param createdByCondition 查询条件
	 */
	public void setCreatedByCondition(Condition<String> createdByCondition) {
		this.createdByCondition = createdByCondition;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return modifiedTimeCondition 查询条件
	 */
	public Condition<LocalDateTime> modifiedTime() {
		this.modifiedTimeCondition = new Condition<>();
		return this.modifiedTimeCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return modifiedTimeCondition 查询条件
	 */
	public Condition<LocalDateTime> getModifiedTimeCondition() {
		return modifiedTimeCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param modifiedTimeCondition 查询条件
	 */
	public void setModifiedTimeCondition(Condition<LocalDateTime> modifiedTimeCondition) {
		this.modifiedTimeCondition = modifiedTimeCondition;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return modifiedByCondition 查询条件
	 */
	public Condition<String> modifiedBy() {
		this.modifiedByCondition = new Condition<>();
		return this.modifiedByCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return modifiedByCondition 查询条件
	 */
	public Condition<String> getModifiedByCondition() {
		return modifiedByCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param modifiedByCondition 查询条件
	 */
	public void setModifiedByCondition(Condition<String> modifiedByCondition) {
		this.modifiedByCondition = modifiedByCondition;
	}

	/**
	 * 构造并返回逻辑删除，1表示已删除,0表示未删除查询条件
	 *
	 * @return delCondition 逻辑删除，1表示已删除,0表示未删除查询条件
	 */
	public Condition<Boolean> del() {
		this.delCondition = new Condition<>();
		return this.delCondition;
	}

	/**
	 * 获取逻辑删除，1表示已删除,0表示未删除查询条件
	 *
	 * @return delCondition 逻辑删除，1表示已删除,0表示未删除查询条件
	 */
	public Condition<Boolean> getDelCondition() {
		return delCondition;
	}

	/**
	 * 设置逻辑删除，1表示已删除,0表示未删除查询条件
	 *
	 * @param delCondition 逻辑删除，1表示已删除,0表示未删除查询条件
	 */
	public void setDelCondition(Condition<Boolean> delCondition) {
		this.delCondition = delCondition;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return delByCondition 查询条件
	 */
	public Condition<String> delBy() {
		this.delByCondition = new Condition<>();
		return this.delByCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return delByCondition 查询条件
	 */
	public Condition<String> getDelByCondition() {
		return delByCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param delByCondition 查询条件
	 */
	public void setDelByCondition(Condition<String> delByCondition) {
		this.delByCondition = delByCondition;
	}

	/**
	 * 构造并返回查询条件
	 *
	 * @return delTimeCondition 查询条件
	 */
	public Condition<LocalDateTime> delTime() {
		this.delTimeCondition = new Condition<>();
		return this.delTimeCondition;
	}

	/**
	 * 获取查询条件
	 *
	 * @return delTimeCondition 查询条件
	 */
	public Condition<LocalDateTime> getDelTimeCondition() {
		return delTimeCondition;
	}

	/**
	 * 设置查询条件
	 *
	 * @param delTimeCondition 查询条件
	 */
	public void setDelTimeCondition(Condition<LocalDateTime> delTimeCondition) {
		this.delTimeCondition = delTimeCondition;
	}

}
